package com.source.lightfowl.person.service.impl;

import com.source.lightfowl.person.dao.BigPlateDao;
import com.source.lightfowl.person.dao.PlateDao;
import com.source.lightfowl.person.entity.Big_Plate;
import com.source.lightfowl.person.entity.Plate;
import com.source.lightfowl.person.service.PlateService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class PlateServiceImpl implements PlateService {
    @Autowired
    private PlateDao plateDao;
    @Autowired
    private BigPlateDao bigPlateDao;
    @Override
    public List<Plate> querryPlate(String rid) {
        return plateDao.findByRid(rid);
    }

    @Override
    public Big_Plate querryBigPlate(String bpid) {
        return bigPlateDao.findByBpid(bpid);
    }

    @Override
    public Plate querryPlateByPid(String pid) {
        return plateDao.findByPid(pid);
    }

    @Override
    public Plate querryPlate(String ptype, String bpid) {
        return plateDao.findByPtypeAndBpid(ptype, bpid);
    }
}
